﻿
''' <summary>
''' 空间数据
''' 映射表: space_data
''' </summary>
Public Class SpaceDataMapper
    Private db As IMySqlService = New MySqlServiceImpl

    Public Function [Select]() As DataTable
        Dim sql As String = <sql>
                                select * from space_data where 1 = 1
                            </sql>
        Return db.select(sql)
    End Function

    Public Function [Select_ById](ByVal id As Integer) As DataTable
        Dim sql As String = <sql>
                                select * from space_data where sid = {0}
                            </sql>
        Return db.select(String.Format(sql, id))
    End Function

    Public Function [Select_ByIds](ByVal ids As Integer()) As DataTable
        Dim sql As String = <sql>
                                select * from space_data where sid = {0}
                            </sql>
        Return db.select(String.Format(sql, String.Join(",", ids)))
    End Function

End Class
